const routingWhiteList = [
  '/',
  '/list',
  '/user',
  '/demo',
  '/upload',
  '/games',
  '/pp',
  '/spider',
  '/test',
];

export function middleWareAll(req, res, next) {
  console.log(req.originalUrl, '进入全局拦截器中');

  if (
    routingWhiteList.some((originalUrl: string) =>
      req.originalUrl.includes(originalUrl),
    )
  ) {
    next();
  } else {
    res.send({ code: 200 });
  }
}
